<?php
require_once __DIR__. '/vendor/autoload.php';

use App\annotations\Value;
use App\test\MyRedis;
use Doctrine\Common\Annotations\AnnotationReader;
// use Doctrine\Common\Annotations\AnnotationRegistry;


//注册 注解的namespace
// AnnotationRegistry::registerAutoloadNamespace("App\annotations");
$annotationReader = new AnnotationReader();

// $rc=new ReflectionClass(MyRedis::class);
$reflectionProperty = new ReflectionProperty(MyRedis::class, 'conn_url');
$propertyAnnotations = $annotationReader->getPropertyAnnotations($reflectionProperty);
// $p=$rc->getProperty("conn_url");
print_r($propertyAnnotations);

// $reader = new AnnotationReader();
// $anno=$reader->getPropertyAnnotation($p,Value::class);var_dump("anno",$anno);
// echo $anno->name;








